//
//  CorrectTabCell.m
//  BestLearning
//
//  Created by edz on 2018/2/1.
//  Copyright © 2018年 apple. All rights reserved.
//

#import "CorrectTabCell.h"

@implementation CorrectTabCell
-(instancetype)initWithStyle:(UITableViewCellStyle)style reuseIdentifier:(NSString *)reuseIdentifier
{
    self = [super initWithStyle:style reuseIdentifier:reuseIdentifier];
    if (self) {
        self.contentView.backgroundColor=RGBColor(245, 245, 245);
        [self setUI];
    }
    
    return self;
}
-(void)setUI
{
    
    UIView *backView = [[UIView alloc]init];
    [self.contentView addSubview:backView];
    backView.backgroundColor = [UIColor whiteColor];
    [backView mas_makeConstraints:^(MASConstraintMaker *make) {
        make.left.top.offset(10);
        make.right.offset(-10);
        make.height.offset(100);
    }];
    
    _titLab = [[UILabel alloc]init];
    [backView addSubview:_titLab];
   _titLab.font  = [UIFont systemFontOfSize:16];
    [_titLab mas_makeConstraints:^(MASConstraintMaker *make) {
        make.left.offset(10);
        make.top.offset(15);
    }];
    
   _correctLab = [[UILabel alloc]init];
    [backView addSubview:_correctLab];
     _correctLab.font  = [UIFont systemFontOfSize:14];
    [_correctLab mas_makeConstraints:^(MASConstraintMaker *make) {
        make.left.offset(10);
        make.top.equalTo(_titLab.mas_bottom).offset(20);
        make.height.offset(30);
    }];

    _strongBtn = [[UIButton alloc]init];
    [backView addSubview:_strongBtn];
    [_strongBtn setFont:[UIFont systemFontOfSize:13]];
    [_strongBtn setTitleColor:[UIColor blackColor] forState:0];
    _strongBtn.layer.borderWidth=1;
    _strongBtn.layer.borderColor = [UIColor blackColor].CGColor;
    _strongBtn.layer.masksToBounds=YES;
    
    [_strongBtn mas_makeConstraints:^(MASConstraintMaker *make) {
        make.right.offset(-6);
        make.top.equalTo(_titLab.mas_bottom).offset(20);
        make.width.offset(76);
        make.height.offset(33);
    }];
    
   
}
- (void)awakeFromNib {
    [super awakeFromNib];
    // Initialization code
}

- (void)setSelected:(BOOL)selected animated:(BOOL)animated {
    [super setSelected:selected animated:animated];

    // Configure the view for the selected state
}

@end
